
from random import choice
group_A=['Feng','Tan','Liu'];group_B=['Zhou','Lei','Yang']
print('Round 1: Who comes to the group A ?')
a=choice(['Zhang','Jian']);print(a)
if a == 'Zhang':
    x=1
else:
    x=0
print('Round 2: Which group does Zhang go to ?')
b=choice(['A','B']);print(b)
if b == 'A':
    x=x+1
else:
    x=x
print('Round 3: Which group does Jian go to ?')
c=choice(['A','B']);print(c)
if c == 'A':
    x=x
else:
    x=x+1
if x >= 2:
    group_A.append('Zhang');group_B.append('Jian')
else:
    group_A.append('Jian');group_B.append('Zhang')
print('Round 4: Who comes to the group A ?')
d=choice(['Chang','Suo']);print(d)
if d == 'Chang':
    group_A.append('Chang');group_B.append('Suo')
else:
    group_A.append('Suo');group_B.append('Chang')
print('Now let us see the final result: ')
print('group A:',group_A)
print('group B:',group_B)
